#include "stddef.h"

#if !defined(_MSC_VER) && !defined(BSD)
	#include "stdint.h"
#else
	typedef unsigned char uint8_t;
	typedef unsigned uint32_t;
	typedef unsigned long long uint64_t;
#endif

#if __STDC_VERSION__ >= 199901L || defined(__GNUC__)
	#include "stdbool.h"
#else
	#ifndef bool
		typedef enum {false, true} _Bool;
		#define bool _Bool
	#endif
#endif

#if __STDC_VERSION__ < 199901L
	#ifndef inline
		#define inline __inline
	#endif
#endif

#if defined(WIN32) || defined(_WIN32) || defined(__WIN32__)
	#ifndef WIN32
		#define WIN32
	#endif
	#ifdef CRTL
		#ifdef __GNUC__
			#define API __declspec(dllimport) __cdecl
		#else
			#define API __cdecl
		#endif
	#else
		#define API __stdcall
	#endif
	#ifdef __BORLANDC__
		#define INTERFACE __cdecl
		#define INTERFACE_FAST __fastcall
	#else
		#define INTERFACE __cdecl
		#define INTERFACE_FAST __cdecl
	#endif
	#define INTERNAL __stdcall
	#define INTERNAL_FAST __fastcall
#elif defined(__GNUC__) && defined(BSD)
	#define API
	#define INTERFACE
	#define INTERFACE_FAST
	#define INTERNAL
	#define INTERNAL_FAST
#else
	#define API __cdecl
	#define INTERFACE __cdecl
	#define INTERFACE_FAST __cdecl
	#define INTERNAL __stdcall
	#define INTERNAL_FAST __fastcall
#endif
